package org.xhy.ruleengine.tree;

import java.util.List;

/**
 * @description:
 * @gitee: https://gitee.com/XhyQAQ
 * @copyright: B站: https://space.bilibili.com/152686439
 * @Author: Xhy
 * @CreateTime: 2024-06-23 12:20
 */
public class Node {

    private String expression;

    private List<Node> childNodes;

    private Object result;

    private Boolean type; // true:规则节点,false:结果节点

    public String getExpression() {
        return expression;
    }

    public void setExpression(String expression) {
        this.expression = expression;
    }

    @Override
    public String toString() {
        return "Node{" +
                "expression='" + expression + '\'' +
                ", childNodes=" + childNodes +
                ", result=" + result +
                ", type=" + type +
                '}';
    }

    public List<Node> getChildNodes() {
        return childNodes;
    }

    public void setChildNodes(List<Node> childNodes) {
        this.childNodes = childNodes;
    }

    public Object getResult() {
        return result;
    }

    public void setResult(Object result) {
        this.result = result;
    }

    public Boolean getType() {
        return type;
    }

    public void setType(Boolean type) {
        this.type = type;
    }
}
